<!--
 * @Author: your name
 * @Date: 2020-08-10 11:14:37
 * @LastEditTime: 2020-08-11 09:36:08
 * @LastEditors: Please set LastEditors
 * @Description: In User Settings Edit
 * @FilePath: \devopsh:\project\QMangolia-web\src\views\code\index.vue
-->
<template>
  <div class="app-container">
    <div>
      <Header-Tab :tab-name="tabName" :tab-list="tabList" @tabChange="tabChange">
        <component v-for="(item, index) in tabList" :key="index" :is="item.name" :slot="item.name"></component>
      </Header-Tab>
    </div>
  </div>
</template>

<script>
import HeaderTab from '@/components/HeaderTab';
export default {
  components: {
    HeaderTab,
    repository: () => import('./repository'),
    branch: () => import('./branch'),
    merge: () => import('./merge')
  },
  data() {
    return {
      tabName: 'repository',
      currentIndex: 0,
      tabList: [
        { label: '托管', name: 'repository' },
        { label: '分支设置', name: 'branch' },
        { label: '代码合并', name: 'merge' },
      ],
    };
  },
  methods: {
    tabChange(event) {
    },
  },
};
</script>

<style lang="scss" scoped>
</style>
